package cn.gzjp.modules.woms.entity;

import com.google.common.collect.Lists;
import org.hibernate.validator.constraints.Length;

import cn.gzjp.common.persistence.DataEntity;
import cn.gzjp.common.utils.excel.annotation.ExcelField;

import java.util.List;

/**
 * 工单处理过程Entity
 * @author liyp
 * @version 2018-07-15
 */
public class EventProcess extends DataEntity<EventProcess> {
	
	private static final long serialVersionUID = 1L;
	private String eventId;		// 工单编号
	private Worker worker;		// 工作人员
	private String status;		// 最新状态
	private String content;		// 操作内容

	private List<EventPic> eventPicList = Lists.newArrayList();//处理过程图片(上传的图片)
	
	public EventProcess() {
		super();
	}

	public EventProcess(String id){
		super(id);
	}

	@Length(min=0, max=32, message="工单编号长度必须介于 0 和 32 之间")
	@ExcelField(title="工单编号", align=2, sort=1)
	public String getEventId() {
		return eventId;
	}

	public void setEventId(String eventId) {
		this.eventId = eventId;
	}
	
	public Worker getWorker() {
		return worker;
	}

	public void setWorker(Worker worker) {
		this.worker = worker;
	}
	
	@Length(min=0, max=1, message="最新状态长度必须介于 0 和 1 之间")
	@ExcelField(title="最新状态", align=2, sort=3)
	public String getStatus() {
		return status;
	}

	public void setStatus(String status) {
		this.status = status;
	}
	
	@Length(min=0, max=512, message="操作内容长度必须介于 0 和 512 之间")
	@ExcelField(title="操作内容", align=2, sort=4)
	public String getContent() {
		return content;
	}

	public void setContent(String content) {
		this.content = content;
	}

	public List<EventPic> getEventPicList() {
		return eventPicList;
	}

	public void setEventPicList(List<EventPic> eventPicList) {
		this.eventPicList = eventPicList;
	}
}